.class Les/vc$a;
.super Ljava/lang/Thread;
.source "DynamicThreadPool.java"


# annotations
.annotation system Ldalvik/annotation/EnclosingClass;
    value = Les/vc;
.end annotation

.annotation system Ldalvik/annotation/InnerClass;
    accessFlags = 0x2
    name = "a"
.end annotation


# instance fields
.field private final a:I

.field private final b:I

.field final synthetic c:Les/vc;


# direct methods
.method public constructor <init>(Les/vc;III)V
    .locals 1

    .line 1
    iput-object p1, p0, Les/vc$a;->c:Les/vc;

    .line 2
    new-instance p1, Ljava/lang/StringBuilder;

    invoke-direct {p1}, Ljava/lang/StringBuilder;-><init>()V

    const-string v0, "worker-"

    invoke-virtual {p1, v0}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {p1, p2}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    const-string p2, "-"

    invoke-virtual {p1, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {p1, p4}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {p1, p2}, Ljava/lang/StringBuilder;->append(Ljava/lang/String;)Ljava/lang/StringBuilder;

    invoke-virtual {p1, p3}, Ljava/lang/StringBuilder;->append(I)Ljava/lang/StringBuilder;

    invoke-virtual {p1}, Ljava/lang/StringBuilder;->toString()Ljava/lang/String;

    move-result-object p1

    invoke-direct {p0, p1}, Ljava/lang/Thread;-><init>(Ljava/lang/String;)V

    .line 3
    iput p3, p0, Les/vc$a;->a:I

    .line 4
    iput p4, p0, Les/vc$a;->b:I

    return-void
.end method


# virtual methods
.method public run()V
    .locals 6

    .line 1
    :try_start_0
    invoke-static {}, Ljava/lang/Thread;->currentThread()Ljava/lang/Thread;

    move-result-object v0

    iget v1, p0, Les/vc$a;->b:I

    invoke-virtual {v0, v1}, Ljava/lang/Thread;->setPriority(I)V
    :try_end_0
    .catchall {:try_start_0 .. :try_end_0} :catchall_0

    goto :goto_0

    :catchall_0
    move-exception v0

    .line 2
    sget-boolean v1, Les/u6;->b:Z

    if-nez v1, :cond_4

    .line 3
    :cond_0
    :goto_0
    iget-object v0, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v0}, Les/vc;->a(Les/vc;)Z

    move-result v0

    if-eqz v0, :cond_3

    .line 4
    iget-object v0, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v0}, Les/vc;->b(Les/vc;)Ljava/util/Queue;

    move-result-object v0

    monitor-enter v0

    .line 5
    :try_start_1
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->b(Les/vc;)Ljava/util/Queue;

    move-result-object v1

    invoke-interface {v1}, Ljava/util/Queue;->isEmpty()Z

    move-result v1

    const/4 v2, 0x0

    if-nez v1, :cond_1

    .line 6
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->b(Les/vc;)Ljava/util/Queue;

    move-result-object v1

    invoke-interface {v1}, Ljava/util/Queue;->poll()Ljava/lang/Object;

    move-result-object v1

    move-object v2, v1

    check-cast v2, Ljava/lang/Runnable;

    goto :goto_1

    .line 7
    :cond_1
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->c(Les/vc;)I

    move-result v1

    iget-object v3, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v3}, Les/vc;->e(Les/vc;)I

    move-result v3

    if-le v1, v3, :cond_2

    .line 8
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->f(Les/vc;)[Ljava/lang/Thread;

    move-result-object v1

    iget v3, p0, Les/vc$a;->a:I

    iget-object v4, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v4}, Les/vc;->f(Les/vc;)[Ljava/lang/Thread;

    move-result-object v4

    iget-object v5, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v5}, Les/vc;->c(Les/vc;)I

    move-result v5

    add-int/lit8 v5, v5, -0x1

    aget-object v4, v4, v5

    aput-object v4, v1, v3

    .line 9
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->f(Les/vc;)[Ljava/lang/Thread;

    move-result-object v1

    iget-object v3, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v3}, Les/vc;->c(Les/vc;)I

    move-result v3

    add-int/lit8 v3, v3, -0x1

    aput-object v2, v1, v3

    .line 10
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->d(Les/vc;)I

    .line 11
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->b(Les/vc;)Ljava/util/Queue;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/Object;->notify()V

    .line 12
    monitor-exit v0
    :try_end_1
    .catchall {:try_start_1 .. :try_end_1} :catchall_2

    goto :goto_2

    .line 13
    :cond_2
    :try_start_2
    iget-object v1, p0, Les/vc$a;->c:Les/vc;

    invoke-static {v1}, Les/vc;->b(Les/vc;)Ljava/util/Queue;

    move-result-object v1

    invoke-virtual {v1}, Ljava/lang/Object;->wait()V
    :try_end_2
    .catch Ljava/lang/InterruptedException; {:try_start_2 .. :try_end_2} :catch_0
    .catchall {:try_start_2 .. :try_end_2} :catchall_2

    .line 14
    :catch_0
    :goto_1
    :try_start_3
    monitor-exit v0
    :try_end_3
    .catchall {:try_start_3 .. :try_end_3} :catchall_2

    if-eqz v2, :cond_0

    .line 15
    :try_start_4
    invoke-interface {v2}, Ljava/lang/Runnable;->run()V
    :try_end_4
    .catchall {:try_start_4 .. :try_end_4} :catchall_1

    goto/16 :goto_0

    :catchall_1
    nop

    goto/16 :goto_0

    :catchall_2
    move-exception v1

    .line 16
    :try_start_5
    monitor-exit v0
    :try_end_5
    .catchall {:try_start_5 .. :try_end_5} :catchall_2

    throw v1

    :cond_3
    :goto_2
    return-void

    .line 17
    :cond_4
    invoke-virtual {v0}, Ljava/lang/Throwable;->toString()Ljava/lang/String;

    move-result-object v1

    const-string v2, "DynamicThreadPool$Worker"

    invoke-static {v2, v1}, Lcom/esfile/screen/recorder/media/util/k;->a(Ljava/lang/String;Ljava/lang/String;)V

    .line 18
    goto :goto_4

    :goto_3
    throw v0

    :goto_4
    goto :goto_3
.end method
